SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO
-- =============================================
-- Author:		<Author,,Name>
-- Create date: <Create Date,,>
-- Description:	<Description,,>
-- =============================================
CREATE PROCEDURE [dbo].[AddMember]
	-- Add the parameters for the stored procedure here
	@fullname nvarchar(max), @Mobile nvarchar(11), @HomePhone nvarchar(10),
	@Email nvarchar, @committeName nvarchar, @CollegeName nvarchar, @UniversityName nvarchar,
	@PositionName nvarchar, @state bit, @address nvarchar, @hiredate date, @BirthDate date, 
	@ProfilePicture nvarchar, @Comments nvarchar
	 
AS
BEGIN
    
	Insert Into Member 
	Values (@Fullname,
	 @Mobile,
	 @HomePhone,
	 @Email,
	 dbo.GetCommitteId(@committeName),
	 dbo.GetCollegeId(@CollegeName),
	 dbo.GetUniversityId(@UniversityName),
	 dbo.GetPosId(@PositionName), 
	 @state,
	 @address, 
	 @hiredate, 
	 @BirthDate, 
	 @ProfilePicture, 
	 @Comments
	 );
	
END
GO
